New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make search APIs consistently accept a query param #4074
Labels
Comments
I'd consider removing the current count api and make it a shortcut to a search request with |
ghost
assigned martijnvg
Dec 16, 2013
I think also the |
martijnvg
added a commit
to martijnvg/elasticsearch
that referenced
this issue
Dec 17, 2013
…ield. The following APIs now accept the query in a top level `query` field like: * delete_by_query * validate_query * count These APIs used to accept the query directly in the request body which was inconsistent with the search and explain APIs. For this reason this is a breaking change. Closes elastic#4074
brusic
pushed a commit
to brusic/elasticsearch
that referenced
this issue
Jan 19, 2014
…ield. The following APIs now accept the query in a top level `query` field like: * delete_by_query * validate_query * count These APIs used to accept the query directly in the request body which was inconsistent with the search and explain APIs. For this reason t Closes elastic#4074
brusic
pushed a commit
to brusic/elasticsearch
that referenced
this issue
Jan 19, 2014
javanna
added a commit
that referenced
this issue
Feb 13, 2014
…vel query object, same as other apis Relates to #4074
This was referenced Mar 25, 2015
s1monw
added a commit
to s1monw/elasticsearch
that referenced
this issue
Jun 3, 2015
This is happening because of elastic#4074 when we required that the top-level "query" is present to delete-by-query requests, but prior to that we required that it is not present. So the translog has a DBQ without "query" and when we try to parse it we hit this exception. This commit adds special handling for pre 1.0.0 indices if we hit parse exception, we try to reparse without a top-level query object to be BWC compatible for these indices. Closes elastic#10262
s1monw
added a commit
that referenced
this issue
Jun 3, 2015
This is happening because of #4074 when we required that the top-level "query" is present to delete-by-query requests, but prior to that we required that it is not present. So the translog has a DBQ without "query" and when we try to parse it we hit this exception. This commit adds special handling for pre 1.0.0 indices if we hit parse exception, we try to reparse without a top-level query object to be BWC compatible for these indices. Closes #10262
s1monw
added a commit
that referenced
this issue
Jun 3, 2015
This is happening because of #4074 when we required that the top-level "query" is present to delete-by-query requests, but prior to that we required that it is not present. So the translog has a DBQ without "query" and when we try to parse it we hit this exception. This commit adds special handling for pre 1.0.0 indices if we hit parse exception, we try to reparse without a top-level query object to be BWC compatible for these indices. Closes #10262 Conflicts: src/main/java/org/elasticsearch/index/shard/IndexShard.java src/test/java/org/elasticsearch/index/shard/IndexShardTests.java
s1monw
added a commit
that referenced
this issue
Jun 3, 2015
This is happening because of #4074 when we required that the top-level "query" is present to delete-by-query requests, but prior to that we required that it is not present. So the translog has a DBQ without "query" and when we try to parse it we hit this exception. This commit adds special handling for pre 1.0.0 indices if we hit parse exception, we try to reparse without a top-level query object to be BWC compatible for these indices. Closes #10262 Conflicts: src/test/java/org/elasticsearch/index/shard/IndexShardTests.java
mute
pushed a commit
to mute/elasticsearch
that referenced
this issue
Jul 29, 2015
…vel query object, same as other apis Relates to elastic#4074 Closes elastic#5111
mute
pushed a commit
to mute/elasticsearch
that referenced
this issue
Jul 29, 2015
…me as other apis Relates to elastic#4074
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The
search
andexplain
APIs both accept aquery
parameter in the body, whilecount
andvalidate_query
expect the body to be the query itself.We should change the
count
andvalidate_query
APIs to accept aquery
parameter. Possibly even change thecount
request to use the same code as for_search
(withsearch_type=count
).The text was updated successfully, but these errors were encountered: